<?php
global $dictionary;
global $iscontrol;

$user = Utils::getUserBySerial($dictionary['creator']);
$dictionary['creator'] = $user['nickname'] == ""?$user['id']:$user['nickname'];
?>
<div id="tool-bar">
	<ul class="meta">
		<li><strong><?=$dictionary['term_num']?></strong>Terms</li>
		<li class="last">Owned by<strong><?=$dictionary['creator']?></strong></li>
	</ul>
	<?php if($iscontrol) {?>
	<ul class="piece">
		<li><a href="<?=REQUEST_BASE?>dictionary/<?=$dictionary['serial']?>/sources/" class="button">Sources</a></li>
		<li><a href="<?=REQUEST_BASE?>dictionary/<?=$dictionary['serial']?>/edit/" class="button">Edit</a></li>
		<li>
			<a href="#" class="button" onclick="dictionary.delete_dictionary(<?=$dictionary['serial']?>, '<?=$dictionary['title']?>');return false;">Delelte</a>
		</li>
	</ul>
	<?php } ?>
	<div class="clear"></div>
</div>